<template>
  <div>
    <h1>欢迎来到仪表盘</h1>
    <el-button @click="logout">登出</el-button>
  </div>
</template>

<script>
export default {
  name: 'Dashboard',
  methods: {
    logout() {
      localStorage.removeItem('token');
      this.$router.push('/login');
    }
  }
};
</script>
